'''
从本地文件，加载模版
'''
from langchain_core.prompts import load_prompt

# 在yaml文件中加载
def load_prompt_from_yaml_file(file_path):
    prompt = load_prompt(file_path)
    print(prompt.format(adjective="funny", content="chickens"))

# 在json文件中加载
def load_prompt_from_json_file(file_path):
    prompt = load_prompt(file_path)
    print(prompt.format(adjective="funny", content="chickens"))

def laod_file_1():
    file_path = "../../load_file/simple_prompt.yaml"
    load_prompt_from_yaml_file(file_path)

def laod_file_2():
    file_path = "../../load_file/simple_prompt.json"
    load_prompt_from_yaml_file(file_path)

def laod_file_3():
    file_path = "../../load_file/simple_prompt_with_template_file.json"
    load_prompt_from_yaml_file(file_path)

def laod_file_4():
    file_path = "../../load_file/few_shot_prompt.yaml"
    load_prompt_from_yaml_file(file_path)
